package com.example.rabbitmq.demo4_priority_queue;

import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @Author songyahui
 * @Date 2023/7/13 9:42
 * @Description
 */
@Slf4j
@Component
public class PriorityConsumer {

    @RabbitListener(queues = "priority_queue")
    public void receiveConfirmMessage(Message message){
        log.warn("排序处理！消息：{}", new String(message.getBody()));
    }

}
